package tt.dz.entity.charger;

import java.io.Serializable;
import java.math.BigDecimal;
import java.sql.Time;
import java.text.SimpleDateFormat;
import java.util.Date;

import tt.dz.util.annotation.Ignore;
import tt.dz.util.annotation.PrimaryKey;
import tt.dz.util.annotation.Table;

/**
 * 电桩费率表
 * @author xielongfei
 * @modify pengyu
 *
 */
@Table(name = "oms_charger_rate")
public class OmsChargerRate implements Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 7178526488540562939L;
	@Ignore
	SimpleDateFormat format = new SimpleDateFormat("HH:mm");
//	SimpleDateFormat format = new SimpleDateFormat("yyyyMMddHHmmss");
//	String s=new SimpleDateFormat("yyyy-MM-dd").format(new java.sql.Date());
	
	/** 费率方案号 */
	@PrimaryKey
	private Integer rate_schema;
	@PrimaryKey
	/** 序号 */
	private Integer serial_no;
	/** 费率名称 */
	private String rate_name;
	/** 费用类型:0：预约费用；1：充电费用；2：充电服务费 */
	private Integer fee_type;
	/** 开始时间 */
	private Time start_time;
	/** 结束时间 */
	private Time end_time;
	/** 1：基础费率中得1号费率\r\n 2：基础费率中得2号费率\r\n 3：基础费率中得3号费率\r\n 4：基础费率中得4号费率 */
	private BigDecimal rate;
	/** 设置人ID */
	private String oper_id;
	/** 设置时间 */
	private Date set_time;
	private Integer valid_flag;
	/**标记按次 按时收费*/
	private Integer charge_mode;

	private Integer default_ind;
	private String default_for;

	@Ignore
	private String start_time_str;
	@Ignore
	private String end_time_str;
	@Ignore
	private String set_time_str;


	
	public OmsChargerRate() {
		super();
	}
	
	public OmsChargerRate(Integer rate_schema) {
		super();
		this.rate_schema = rate_schema;
	}
	public Integer getRate_schema() {
		return rate_schema;
	}
	public void setRate_schema(Integer rate_schema) {
		this.rate_schema = rate_schema;
	}
	public Integer getSerial_no() {
		return serial_no;
	}
	public void setSerial_no(Integer serial_no) {
		this.serial_no = serial_no;
	}
	
	public Integer getFee_type() {
		return fee_type;
	}
	public void setFee_type(Integer fee_type) {
		this.fee_type = fee_type;
	}
	public Time getStart_time() {
		return start_time;
	}
	public void setStart_time(Time start_time) {
		this.start_time = start_time;
	}
	public Time getEnd_time() {
		return end_time;
	}
	public void setEnd_time(Time end_time) {
		this.end_time = end_time;
	}
	 
	public BigDecimal getRate() {
		return rate;
	}
	public void setRate(BigDecimal rate) {
		this.rate = rate;
	}
	public String getOper_id() {
		return oper_id;
	}
	public void setOper_id(String oper_id) {
		this.oper_id = oper_id;
	}
	public Date getSet_time() {
		return set_time;
	}
	public void setSet_time(Date set_time) {
		this.set_time = set_time;
	}
	public Integer getValid_flag() {
		return valid_flag;
	}
	public void setValid_flag(Integer valid_flag) {
		this.valid_flag = valid_flag;
	}
	public Integer getCharge_mode() {
		return charge_mode;
	}
	public void setCharge_mode(Integer charge_mode) {
		this.charge_mode = charge_mode;
	}
	public String getRate_name() {
		return rate_name;
	}
	public void setRate_name(String rate_name) {
		this.rate_name = rate_name;
	}
	public String getStart_time_str() {
		if(getStart_time()!=null){
			return format.format(getStart_time());
		}
		return null;
	}
	public void setStart_time_str(String start_time_str) {
		this.start_time_str = start_time_str;
	}
	public String getEnd_time_str() {
		if(getEnd_time()!=null){
			return format.format(getEnd_time());
		}
		return null;
	}
	public void setEnd_time_str(String end_time_str) {
		this.end_time_str = end_time_str;
	}
	public String getSet_time_str() {
		if(getSet_time()!=null){
			return format.format(getSet_time());
		}
		return null;
	}
	public void setSet_time_str(String set_time_str) {
		this.set_time_str = set_time_str;
	}

	public Integer getDefault_ind()
	{
		return default_ind;
	}

	public void setDefault_ind(Integer default_ind)
	{
		this.default_ind = default_ind;
	}

	public String getDefault_for()
	{
		return default_for;
	}

	public void setDefault_for(String default_for)
	{
		this.default_for = default_for;
	}
}
